
import React from 'react';
import { toJS } from 'mobx';
import { inject, observer } from 'mobx-react';
import { Route, withRouter, Redirect } from 'react-router-dom';
import {Tools, Flex, List, Checkbox, SearchBar, WingBlank, Button, WhiteSpace, Switch } from 'weaver-mobile';
import QueueAnim from 'rc-queue-anim';
import HomeList from "../list";

const CheckboxItem = Checkbox.CheckboxItem;
const Item = List.Item;
const getLabel = Tools.getLabel;

@withRouter
@inject('homeStore')
@observer
class Home extends React.Component {
  static defaultProps = {
    prefixCls: 'msg-setting-home',
  }
  componentDidMount() {
    const { homeStore } = this.props;
    homeStore.getModuleOptions();
    homeStore.getLoadUserMsgConfig();
    document.title = getLabel("19085","消息提醒") + getLabel("30747","设置");
  }

  // componentDidUpdate() {
  //   const { homeStore } = this.props;
  //   const { detailSetting } = homeStore;
  //   document.title = getLabel("19085","消息提醒") + getLabel("30747","设置");
  // }

  render() {
    const { homeStore, prefixCls } = this.props;
    const { selectPage, userMsgConfig } = homeStore;
    document.title = getLabel("19085","消息提醒") + getLabel("30747","设置");
    return (
      <div className="wm-route-layout">
        <HomeList />
      </div>
    )
  }
}

export default Home;
